// 模型对象
const mongoose = require('mongoose')

// 系统用户模型对象
const user_schema = new mongoose.Schema({
    username: String,
    password: {
        type: String,
        select: false
    },
    register_time: String,
    update_time: {
        type: String,
        default: ''
    },
    phone: {
        type: String,
        default: ''
    },
    email: {
        type: String,
        default: ''
    },
    avatar: {
        type: String,
        default: ''
    }
})

const M_user = mongoose.model( 'users', user_schema )

module.exports = { 
    M_user
}
